how to find the most common character in a string java